package com.ruoyi.client.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.client.mapper.SysPurchaseOrderMapper;
import com.ruoyi.client.domain.SysPurchaseOrder;
import com.ruoyi.client.service.ISysPurchaseOrderService;

/**
 * 采购订单 Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-09-14
 */
@Service
public class SysPurchaseOrderServiceImpl implements ISysPurchaseOrderService 
{
    @Autowired
    private SysPurchaseOrderMapper sysPurchaseOrderMapper;

    /**
     * 查询采购订单 
     * 
     * @param purId 采购订单 主键
     * @return 采购订单 
     */
    @Override
    public SysPurchaseOrder selectSysPurchaseOrderByPurId(Long purId)
    {
        return sysPurchaseOrderMapper.selectSysPurchaseOrderByPurId(purId);
    }

    /**
     * 查询采购订单 列表
     * 
     * @param sysPurchaseOrder 采购订单 
     * @return 采购订单 
     */
    @Override
    public List<SysPurchaseOrder> selectSysPurchaseOrderList(SysPurchaseOrder sysPurchaseOrder)
    {
        return sysPurchaseOrderMapper.selectSysPurchaseOrderList(sysPurchaseOrder);
    }

    /**
     * 新增采购订单 
     * 
     * @param sysPurchaseOrder 采购订单 
     * @return 结果
     */
    @Override
    public int insertSysPurchaseOrder(SysPurchaseOrder sysPurchaseOrder)
    {
        return sysPurchaseOrderMapper.insertSysPurchaseOrder(sysPurchaseOrder);
    }

    /**
     * 修改采购订单 
     * 
     * @param sysPurchaseOrder 采购订单 
     * @return 结果
     */
    @Override
    public int updateSysPurchaseOrder(SysPurchaseOrder sysPurchaseOrder)
    {
        return sysPurchaseOrderMapper.updateSysPurchaseOrder(sysPurchaseOrder);
    }

    /**
     * 批量删除采购订单 
     * 
     * @param purIds 需要删除的采购订单 主键
     * @return 结果
     */
    @Override
    public int deleteSysPurchaseOrderByPurIds(Long[] purIds)
    {
        return sysPurchaseOrderMapper.deleteSysPurchaseOrderByPurIds(purIds);
    }

    /**
     * 删除采购订单 信息
     * 
     * @param purId 采购订单 主键
     * @return 结果
     */
    @Override
    public int deleteSysPurchaseOrderByPurId(Long purId)
    {
        return sysPurchaseOrderMapper.deleteSysPurchaseOrderByPurId(purId);
    }
}
